"""
-*- coding:utf-8 -*-
__project_ = 'le-bo16'
__file_name__ = 'lebo01'
__author__ = 'wang'
__time__ = '2020/10/26 21:35'
__product_name = PyCharm
# code is far away from bugs with the god animal protecting
    I love animals. They taste delicious.
             
"""

# print ("hello world")
# list1 =[1,2,3]
# list2 =[6,7,8]
# list3 = list1 + list2
# print(list3)
#  拆包  交换
# 列表拆包
# my_list =["haha","heihei"]
# my_haha,my_heihei=my_list
# print(my_haha)
# 元祖拆包
# my_list =("haha","heihei")
# my_haha,my_heihei=my_list
# print(my_haha)
# def my_func(name,age):
#     return"xingming"+name ,"age"+age
# print(my_func("lebo","18"))
# 函数的拆包
# def my_func(name,age):
#     return"xingming"+name ,"age"+age
# my_name,my_age = my_func("lebo","18")
# print(my_name)
# print(my_age)
# def my_func(name,age):
#     return name ,age
# my_name,my_age = my_func("lebo","18")
# print(my_name)
# print(my_age)
# 递归函数
# # 匿名函数
# def my_print():
#     print("lebo")
# my_print()
# def my_print(a):
#     print("lebo")
# my_print(a)

# 无参数无返回值的匿名函数
# f = lambda:print("lebo")
# f()
# f =lambda a:print(a)
# f(1)
# f = lambda a:a
# print(f(1))
# 列表推导式,只能用在列表中
# []
# my_list = []
# for i in range(1,11):
#     my_list.append(i)
# print(my_list)
#
# def rang(param, param1):
#     pass

# print([i for i in range(1,11)])
# print([i for i in range(1,11)if i%2 ==0])
# 列表推导式
# print([(i,j) for i in range(1,11) for j in range (2,9)])
# for i in range(1,101):
#     print(i)
# a = ([i for i in range(1,101)])
# for i in range(1,len(a),3):
#     print(i)
# ret = a[i:i+3 ]
# 对于列表什么是越界  删除列表的数据 下标就小一个 所以报越界的问题